XIQS Create SIP Device Group

From IQsimWiki

Jump to: navigation, search

XIQS Create SIP Device Group - SIP Device Group Management

Description
createXIQSVoipDvcGroup ( String name , [ Long id_device ] , Integer devicetype [, Long id_partition ] )
Create device group. This command will create empty group. Devices are added into group using addXIQSVoipDvcGroup function
Parameters
String name
Group name
[ Long id_device ]
Optional: an ISC/ICM id to link this group. Not mandatory when group type is "ISC cluster" (9)
Integer devicetype
Group type. Can be one of
  • Gateway - 1
  • Endpoint - 3
  • Trunk - 5
  • ISC cluster - 9
Note: when no id_device is specified, the devicetype can only be "ISC Cluster" (9).
[ Long id_partition ]
Partition Id - Mandatory when current user is administrator.
Return Values
Integer ok (=1) -
Error Data structure ( Error Management )
Possible failure code returns
See Also

addXIQSVoipDvcGroup

Example

Create GSM Device Group
This command will create group of gsm devices (type=1), whose name is GsmDeviceGroupName which will use ISC with ID=21 on partition 3

<?xml version="1.0" encoding="UTF-8">
<command tid="0001" name=" createXIQSVoipDvcGroup ">
  <param type="string">GsmDeviceGroupName</param>
  <param type="long">21</param>
  <param type="integer">1</param>
  <param type="long">3</param>
</command>

[ANSWER (OK)]
Group created with ID=25

<?xml version="1.0" encoding="UTF-8"?>
<event type="return" tid="0001">
  <meta-data>
    <meta-value>
      <name>id</name>
      <pos>1</pos>
    </meta-value>
  </meta-data>
  <param type="long">25</param>
</event>

Create Endpoint Group
This command will create group of endpoints (type=3), whose name is EndpointGroupName. ISC ID is not important for this group type, so it is set to 0. Group is created on partition 3

<?xml version="1.0" encoding="UTF-8">
<command tid="0002" name=" createXIQSVoipDvcGroup ">
  <param type="string"> EndpointGroupName </param>
  <param type="long">0</param>
  <param type="integer">3</param>
  <param type="long">3</param>
</command>

[ANSWER (OK)]
Endpoint Group created with ID=17

<?xml version="1.0" encoding="UTF-8"?>
<event type="return" tid="0002">
  <meta-data>
    <meta-value>
      <name>id</name>
      <pos>1</pos>
    </meta-value>
  </meta-data>
  <param type="long">17</param>
</event>

Create VoIP Trunk Group
This command will create group of VoIP Trunks (type=5), whose name is VoIPTrunkGroupName. ISC ID is not important for this group type, so it is set to 0. Group is created on partition 3

<?xml version="1.0" encoding="UTF-8">
<command tid="0003" name=" createXIQSVoipDvcGroup ">
  <param type="string"> VoIPTrunkGroupName </param>
  <param type="long">0</param>
  <param type="integer">5</param>
  <param type="long">3</param>
</command>

[ANSWER (OK)]
VoIP Trunk Group created with ID=7

<?xml version="1.0" encoding="UTF-8"?>
<event type="return" tid="0003">
  <meta-data>
    <meta-value>
      <name>id</name>
      <pos>1</pos>
    </meta-value>
  </meta-data>
  <param type="long">7</param>
</event>

Create ISC Cluster
This command will create ISC Cluster (type=9), whose name is IscClusterName. ISC ID is not important can be set to 0 or this second parameter can be skipped. Group is created on partition 3
Example with second parameter set to 0

<?xml version="1.0" encoding="UTF-8">
<command tid="0004" name=" createXIQSVoipDvcGroup ">
  <param type="string"> IscClusterName </param>
  <param type="long">0</param>
  <param type="integer">9</param>
  <param type="long">3</param>
</command>
Example without second parameter
<?xml version="1.0" encoding="UTF-8">
<command tid="0004" name=" createXIQSVoipDvcGroup ">
  <param type="string"> IscClusterName </param>
  <param type="integer">9</param>
  <param type="long">3</param>
</command>

[ANSWER (OK)]
ISC Cluster created with ID=22

<?xml version="1.0" encoding="UTF-8"?>
<event type="return" tid="0004">
  <meta-data>
    <meta-value>
      <name>id</name>
      <pos>1</pos>
    </meta-value>
  </meta-data>
  <param type="long">22</param>
</event>


Personal tools
Namespaces
Variants
Views
Actions
Navigation
XIQS XML Protocol
XIQS Framework Libraries
XIQS Command List